<div id="<%= dom_id cart %>">
  <h2 class="font-bold text-lg mb-3">Your Cart</h2>

  <table class="table-auto">
    <%= render cart.line_items %>

    <tfoot>
    <tr>
      <th class="text-right pr-2 pt-2" colspan="3">Total:</th>
      <td class="text-right pt-2 font-bold border-t-2 border-black">
        <%= number_to_currency(cart.total_price) %>
      </td>
    </tr>
    </tfoot>
  </table>
  <%= button_to 'Empty Cart', cart, method: :delete,
                class: 'ml-4 rounded-lg py-1 px-2 text-white bg-green-600' %>
</div>